//
//  TestProblem1491.swift
//  LeetCodeTests
//
//  Created by 武侠 on 2023/6/25.
//  Copyright © 2023 zhulongiMac02. All rights reserved.
//

import XCTest
@testable import LeetCode

final class TestProblem1491: XCTestCase {

    var problem = Problem1491()
    
    override func setUp() {
        super.setUp()
        // Put setup code here. This method is called before the invocation of each test method in the class.
    }
    
    override func tearDown() {
        // Put teardown code here. This method is called after the invocation of each test method in the class.
        super.tearDown()
    }
    
    // MARK: - 排序
    func testProblem1491_Case1() throws {
        XCTAssertEqual(problem.average([4000,3000,1000,2000]), 2500.0)
    }
    
    func testProblem1491_Case2() throws {
        XCTAssertEqual(problem.average([1000,2000,3000]), 2000.0)
    }
    
    func testProblem1491_Case3() throws {
        XCTAssertEqual(problem.average([6000,5000,4000,3000,2000,1000]), 3500.0)
    }
    
    func testProblem1491_Case4() throws {
        XCTAssertEqual(problem.average([8000,9000,2000,3000,6000,1000]), 4750.0)
    }
}
